<template>
  <div class="home">
  </div>
</template>

<script>
//并发请求，同事进行多个请求，并统一处理返回值
import axios from 'axios'
export default {
  name: 'axios2-3',
  components: {
  },
  created(){

    let data = {key:'post'}

    axios.delete('/cache/delete',{params: data})
    
    axios.all(
      [
        axios.get('/cache/get',{params:{key:12}}),
        axios.delete('/cache/delete',{params: data}),
      ]).then(
        axios.sprcead((getRes,deleteRes)=>{
          console.log(getRes,deleteRes)
        })
      )
  },
}
</script>
